#pragma once

#include <iostream>
#include <functional>

// using task_t = std::function<void()>;

// void Download()
// {
//     std::cout << "Download()" << std::endl;
// }


// 任务 
class Task
{
private:
public:
    Task(int x = 100, int y = 100)
        : _x(x), _y(y)
    {}

    void Excute()
    {
        _result = _x + _y;
    }

    void operator()()
    {
        Excute();
    }

    std::string debug()
    {
        std::string msg = std::to_string(_x) + " + " + std::to_string(_y) + " = ?";
        return msg;
    }

    std::string result()
    {
        std::string msg = std::to_string(_x) + " + " + std::to_string(_y) + " = " + std::to_string(_result);
        return msg;
    }
    
private:
    int _x;
    int _y;
    int _result;
};